home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Belgian Amiga Club - ADF Collection
/
BS1 part 19.zip
/
BS1 part 19
/
how to learn assembler.adf
/
CH4
/
4_1A.asm
< prev
next >
Wrap
Assembly Source File
|
1988-02-25
|
560b
|
18 lines
;(41a)
adding1:
clr.l D0 ; Erase D0
move table,d0 ; First entry in D0
add table+2,d0 ; Add second entry
add table+4,d0 ; Add third entry
add table+6,d0 ; Add fourth entry
add table+8,d0 ; Add fifth entry
rts ; return to main program
table: dc.w 2,4,6,8,10
end
;Try out the program using the debugger and single stepping through until
;you get to the RTS command. You can see at this point that data register
;DO really contains the sum of the values.